﻿using System;
using System.IO;

namespace SceneUnpacker.ScanDirectoryDemo
{
    public class DirectoryEventArgs : EventArgs
    {
        private ScanDirectoryAction _action;
        private bool _cancel;
        private DirectoryInfo _directoryInfo;

        private DirectoryEventArgs()
        {
        }

        internal DirectoryEventArgs(DirectoryInfo directory, ScanDirectoryAction action)
        {
            if (directory == null)
            {
                throw new ArgumentNullException("directory");
            }
            this._directoryInfo = directory;
            this._action = action;
        }

        public ScanDirectoryAction Action
        {
            get
            {
                return this._action;
            }
        }

        public bool Cancel
        {
            get
            {
                return this._cancel;
            }
            set
            {
                this._cancel = value;
            }
        }

        public DirectoryInfo Info
        {
            get
            {
                return this._directoryInfo;
            }
        }
    }
}

